//+----------------------------------------------------------------------------------------------+
//| NOTE — Differences from the MQL5 version:                                                    |
//| 1) MQL4 does not have CopyTicksRange() and does not provide access to the bid/ask of each    |
//|    historical tick, so the history is built using bars via                                   |
//|    iVolume(), and the Buy/Sell classification is based on the direction                      |
//|    of the candle (close>=open → buy, otherwise sell).                                        |
//| 2) volume_real is not available in MQL4 — the UseRealVolume parameter                        |
//|    is left for compatibility, but in practice it is always tick count.                       |
//| 3) New incoming ticks (NewTick via OnCalculate/OnTimer)                                      |
//|    are classified correctly by bid/ask, as in the original.                                  |
//+----------------------------------------------------------------------------------------------+

